<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="${package}.mapper.${TableName}Mapper">
<select>
SELECT <#list  columns as field> ${field.column_name!}<#if field_has_next>,</#if> </#list> FROM ${table_name!}
WHERE ${key_name!} = ${r"#{id}"} AND delete_flag!=1
</select>
<delete>
    update ${table_name!} set delete_flag=1
    <where>
        <foreach collection='list' item='item' separator=',' open='(' close=')'>
            ${r"#{item}"}
        </foreach>
    </where>
</delete>
</mapper>
